#ifndef __TYPES_H__
#define __TYPES_H__

/* Tipos de enteros */

typedef unsigned char      	uint_8;
typedef unsigned short     	uint_16;
typedef unsigned int       	uint_32;
typedef unsigned long long 	uint_64;

typedef signed char      	sint_8;
typedef signed short     	sint_16;
typedef signed int       	sint_32;
typedef signed long long 	sint_64;

typedef sint_32 pid;

/* Tipo bool */

typedef int bool;

#define TRUE 	1
#define FALSE 	0

#define NULL 	0

/* Mascaras (de 4 bytes) */

#define BITS_00_01 0x00000003
#define BITS_00_11 0x00000FFF
#define BITS_00_15 0x0000FFFF

#define BITS_12_21 0x003FF000

#define BITS_16_23 0x00FF0000
#define BITS_16_19 0x000F0000

#define BITS_24_31 0xFF000000
#define BITS_22_31 0xFFC00000
#define BITS_16_31 0xFFFF0000
#define BITS_12_31 0xFFFFF000

#endif /* __TYPES_H__ */
